package com.freesky.common.dao.entity;

import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.freesky.common.enums.PanelCategoryEnum;
import com.freesky.common.enums.PanelPositionEnum;
import com.freesky.common.enums.StateEnum;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

@Data
@TableName("tb_panel")
public class Panel extends Model<Panel>{
    @TableId
    private Integer id;

    private String name;

    private PanelCategoryEnum type;

    private Integer sortOrder;

    private PanelPositionEnum position;

    private Integer limitNum;

    private StateEnum state;

    private String remark;

    private Date created;

    private Date updated;
    @TableField(exist =false)
    private List<PanelContent> panelContents;

    @Override
    protected Serializable pkVal() {
        return id;
    }
}
